package com.zt.ftphelper.model;

import java.util.Objects;

/**
 * @author zt
 * @Description:
 * @date 22/08/2019 18:21
 */
public class NameObject {

    private String path;
    private String name;
    private String type;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPath() {
        return path;
    }

    public void setPath(String path) {
        this.path = path;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public NameObject() {
    }

    public NameObject(String path, String name, String type) {
        this.path = path;
        this.name = name;
        this.type = type;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        NameObject that = (NameObject) o;
        return Objects.equals(getPath(), that.getPath()) &&
                getName().equals(that.getName()) &&
                Objects.equals(getType(), that.getType());
    }

    @Override
    public int hashCode() {
        return Objects.hash(getPath(), getName(), getType());
    }
}
